package com.heima.wemedia.utils;

import com.heima.model.common.wemedia.pojos.WmUser;

/**
 * @Author: WDD
 * @Date: 2022/08/02/20:06
 * @Description:
 */
public class WmThreadLocalUtils {

    private final static ThreadLocal WM_THREAD_LOCAL = new ThreadLocal();

    public static void setUser(WmUser wmUser) {
        WM_THREAD_LOCAL.set(wmUser);
    }

    public static WmUser getUser() {
        return (WmUser) WM_THREAD_LOCAL.get();
    }

    public static void remove() {
        WM_THREAD_LOCAL.remove();
    }
}
